<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@taglib prefix="s" uri="/struts-tags"%>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://"
			+ request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
	<head>
		<script type='text/javascript'
			src='<%=request.getContextPath()%>/dwr/interface/studentAction.js'></script>
		<script type='text/javascript'
			src='<%=request.getContextPath()%>/dwr/engine.js'></script>
		<script type='text/javascript'
			src='<%=request.getContextPath()%>/dwr/util.js'></script>
		<link href="<%=request.getContextPath()%>/css/tabcard.css"
			rel="stylesheet" type="text/css">
		<script type='text/javascript'
			src="<%=request.getContextPath()%>/js/tabcard.js">
        </script>
		<script type='text/javascript'>
function stu_BasicInfo(){
	studentAction.getStudentBasicInfo($('student_info').value,stu_BasicInfoCallback);
}
var stu_BasicInfoCallback = function stu_BasicInfoCallbackFunc(stulist){
	var slist = stulist[0];
	$('studentno').value = slist[1];
	$('stuNo').innerHTML = slist[1];
	$('stuName').innerHTML = slist[2];
	$('stuGender').innerHTML = slist[3];
	$('stuCollege').innerHTML = slist[4];
	$('stuMajor').innerHTML = slist[5];
	$('stuClass').innerHTML = slist[6];
	$('stuDorm').innerHTML = slist[7];
	$('stuPhone').innerHTML = slist[8];
	$('studentpicture').src+=slist[9];
}
</script>
	</head>
	<body>
		<div id="student_basic_info">
			<div id="student_basic_info_search">
				请输入学号：
				<input name="textfield" type="text" id="student_info" />
				<input type="submit" name="button" id="button" value="搜索"
					onclick="stu_BasicInfo()" />
			</div>
			<div class="tab_card" id="student_basic_info_tab">
				<ul class="menu">
					<li>
						基本信息
					</li>
					<li>
						历史住宿信息
					</li>
				</ul>
				<div class="tab_card_con">
				<div id="student_basic_info_content2">
					<table class="table_student_basic_info">
						<tr>
							<td class="st_td_left">
								学&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;号：
							</td>
							<td class="st_td_right">
								<div id="stuNo"></div>
							</td>
							<td rowspan="4" colspan="2">
								<div align="center">
									<img id="studentpicture" src="<%=request.getContextPath()%>"
										width="75px" height="100px" alt="头像" />
								</div>
							</td>
						</tr>
						<tr>
							<td class="st_td_left">
								姓&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;名：
							</td>
							<td class="st_td_right">
								<div id="stuName"></div>
							</td>
						</tr>
						<tr>
							<td class="st_td_left">
								性&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;别：
							</td>
							<td class="st_td_right">
								<div id="stuGender"></div>
							</td>
						</tr>
						<tr>
							<td class="st_td_left">
								学&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;院：
							</td>
							<td class="st_td_right">
								<div id="stuCollege"></div>
							</td>
						</tr>
						<tr>
							<td class="st_td_left">
								专&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;业：
							</td>
							<td class="st_td_right">
								<div id="stuMajor"></div>
							</td>
							<td class="st_td_left">
								班&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;级：
							</td>
							<td class="st_td_right">
								<div id="stuClass"></div>
							</td>
						</tr>
						<tr>
							<td class="st_td_left">
								所住宿舍：
							</td>
							<td class="st_td_right">
								<div id="stuDorm"></div>
							</td>
							<td class="st_td_left">
								手机号码：
							</td>
							<td class="st_td_right">
								<div id="stuPhone"></div>
							</td>
						</tr>
						<tr class="table_submit">
							<td colspan="6"></td>
						</tr>
					</table>
				</div>
				<div id="student_basic_info_content3">
					住宿历史信息
				</div>
				</div>
			</div>
		</div>
		<script language="javascript">
            
            /**
             *
             * @param string tabId			当前标签组id
             * @param string fromContendId	要加载的内容的id前缀
             * @param int bindType	绑定方式 0为绑定鼠标移上效果 1为鼠标点击的效果
             * @version 1.0.0
             */
            //TabCard(tabId,fromContendId,bindType)
            
            var tmpObj1 = new TabCard("student_basic_info_tab", "student_basic_info_content", 1);
            tmpObj1.mActiveClass = "active";
            tmpObj1.mNoActiveClass = "default";
            tmpObj1.mListStartNumb = 2;
            tmpObj1.initab();
        </script>
		
	</body>